import request from "@/axios/request";
import url from "@/axios/url";
const { mesUrl } = url();

// 分页查询
export function getList (params = {}) {
  return request({
    url: `${mesUrl}mesCabinetRoleRelation`,
    method: "get",
    params,
  });
}
// 获取角色列表
export function getRoleList (params = {}) {
  return request({
    url: `${mesUrl}mesCabinetRoleRelation/roleCodeList`,
    method: "get",
    params,
  });
}
// 为存放柜区域授权角色
export function setRole (data = {}) {
  return request({
    url: `${mesUrl}mesCabinetRoleRelation`,
    method: "post",
    data,
  });
}
